<script></script>

<template>
  <el-button type="primary" color="rgb(221, 80, 88)" @click="insertButtonClick"
    >点击触发弹窗测试</el-button
  >
  <el-button type="primary" color="rgb(221, 80, 88)" @click="updateButtonClick"
    >点击触发弹窗测试</el-button
  >
  <Submit
    v-model:dialogVisible="insertDialogVisible"
    dialogTitle="新增中"
    :id="1"
    type="insert"
  ></Submit>
  <Submit
    v-model:dialogVisible="updateDialogVisible"
    dialogTitle="更新中"
    :id="1"
    type="update"
  ></Submit>
</template>

<script setup>
import { ref } from "vue";
import Submit from "@/views/index/contribute/submit.vue";
const insertDialogVisible = ref(false);
const updateDialogVisible = ref(false);
// 添加按钮打开
const insertButtonClick = () => {
  insertDialogVisible.value = true;
};
const updateButtonClick = () => {
  updateDialogVisible.value = true;
};
</script>

<style lang="scss"></style>
